home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Mac Magazin/MacEasy 24
/
Mac Magazin and MacEasy Magazine CD - Issue 24.iso
/
Grafik & Text
/
Microsoft Installer Patch
/
notify.c
< prev
next >
Wrap
Text File
|
1995-12-23
|
622b
|
29 lines
// notify.c
#include "notify.h"
void UserNotify( StringPtr s )
{
NMRecPtr notify = nil;
StringPtr nmStr = nil;
// allocate buffer to hold notification record
notify = (NMRecPtr) NewPtrSysClear(sizeof(NMRec) + sizeof(Str255));
if (!notify) { SysBeep(12); return; }
// fill in the string
nmStr = (StringPtr)notify + sizeof(NMRec);
BlockMoveData( s, nmStr, s[0]+1 );
// and the rest of the fields
notify->qLink = 0;
notify->qType = nmType;
notify->nmMark = 0;
notify->nmIcon = 0;
notify->nmSound = (Handle) -1;
notify->nmStr = nmStr;
notify->nmResp = (NMUPP)-1;
// and do it
NMInstall( notify );
}